package com.niiwoo.civet.account.enums;

import lombok.AllArgsConstructor;
import lombok.Getter;

import java.util.ArrayList;
import java.util.List;
import java.util.Objects;

/**
 * 账单二级科目
 *
 * @author xiaoyingping
 * @create 2017-11-22 15:33
 **/
@AllArgsConstructor
@Getter
public enum BillSecondSubjectEnum {

    /**
     * 公用
     */
    ADJUST_ACCOUNT_IN("9001001", "调账(入)", "错账调整", "错账调整", BillFirstSubjectEnum.ADJUST_ACCOUNT_IN),
    ADJUST_ACCOUNT_OUT("9002001", "调账(出)", "错账调整", "错账调整", BillFirstSubjectEnum.ADJUST_ACCOUNT_OUT),


    /**
     * 普通用户（二级科目）
     */
    USER_RECHARGE("1100001", "充值金额", "用户充值", "充值", BillFirstSubjectEnum.USER_RECHARGE),
    USER_RECHARGE_REPAYMENT("1100003", "释放还款金额", "释放还款金额", "充值", BillFirstSubjectEnum.USER_RECHARGE),

    USER_WITHDRAW_BACK("1102001", "提现金额", "用户提现申请失败，提现金额退回用户", "提现退回", BillFirstSubjectEnum.USER_WITHDRAW_BACK),
    USER_WITHDRAW_BACK_SERVICE_FEE("1102003", "提现手续费", "用户提现申请失败，提现手续费退回用户", "提现退回", BillFirstSubjectEnum.USER_WITHDRAW_BACK),

    USER_INVEST_BACK("1104001", "投资金额", "投资失败或借款项目流标后，平台将投资本金退还投资人", "投资退回", BillFirstSubjectEnum.USER_INVEST_BACK),
    USER_INVEST_BACK_SERVICE_FEE("1104003", "投资服务费", "投资失败或借款项目流标后，平台将平台服务费退还投资人", "投资退回", BillFirstSubjectEnum.USER_INVEST_BACK),

    USER_INVEST_REPAYMENT_CORPUS("1106001", "回款本金", "投资人收取借款人/极速借机构/担保人/担保公司回款本金", "投资回款", BillFirstSubjectEnum.USER_INVEST_REPAYMENT),
    USER_INVEST_REPAYMENT_INTEREST("1106003", "回款利息", "投资人收取借款人/极速借机构/担保公司回款利息", "投资回款", BillFirstSubjectEnum.USER_INVEST_REPAYMENT),
    USER_INVEST_PRINCIPAL_PENALTY("1106005", "本金罚息", "担保人/极速借机构/担保公司未垫付，投资人收取担保公司/借款人本金罚息", "投资回款", BillFirstSubjectEnum.USER_INVEST_REPAYMENT),//todo:数据库中不存在
    USER_INVEST_REPAYMENT_PENALTY("1106007", "罚息", "借款人还款逾期，投资人收取借款人罚息", "投资回款", BillFirstSubjectEnum.USER_INVEST_REPAYMENT),
    USER_TRANSFER_CORPUS("1106008", "债转本金", "债权转让成功后,出让人收取受让人债权回款本金", "转让金额", BillFirstSubjectEnum.USER_TRANSFER_CREDITOR),
    USER_TRANSFER_INTEREST("1106009", "债转利息", "债权转让成功后,出让人收取受让人债权回款利息", "转让金额", BillFirstSubjectEnum.USER_TRANSFER_CREDITOR),
    USER_TRANSFER_AMOUNT("1134001", "到账金额", "债权转让成功后,出让人收取受让人债权回款", "转让金额", BillFirstSubjectEnum.USER_TRANSFER_CREDITOR),//todo:数据库中不存在

//    USER_INVEST_PRINCIPAL_ALL("106007","回款总额","本金+利息+罚息的总额记账，用于查询账单列表显示",USER_INVEST_REPAYMENT,null,null,null,BillUserTypeEnum.user_type.getOrdinaryUser()),
//    USER_GUARANTEE_BACK_SERVICE_FEE("108001","平台服务费【担】退回","借款项目流标后，平台将担保服务费退还担保人",USER_GUARANTEE_BACK,null,null,null),//借款放款后

    USER_GUARANTEE_BACK_BAIL("1108001", "担保保证金", "借款项目流标后，平台将担保保证金退还给担保人", "担保退回", BillFirstSubjectEnum.USER_GUARANTEE_BACK),
    USER_GUARANTEE_SERVICE_FEE("1108003", "担保服务费", "借款项目流标后，平台将平台服务费退还担保人", "担保退回", BillFirstSubjectEnum.USER_GUARANTEE_BACK),//todo:数据库中不存在

    USER_GUARANTEE_INCOME("1110001", "担保收益", "信用借借款成标后，担保人收取借款人担保收益", "担保收入", BillFirstSubjectEnum.USER_GUARANTEE_INCOME),
    USER_GUARANTEE_INCOME_FEE("1110003", "尽调费", "信用借借款成标后，尽调人收取借款人担保收益", "尽调", BillFirstSubjectEnum.USER_GUARANTEE_INCOME),
    USER_GUARANTEE_INCOME_BONUS("1110005", "尽调奖励", "尽调报告审核通过，但尽调人放弃担保或项目流标，平台给予尽调人奖励", "平台奖励", BillFirstSubjectEnum.USER_GUARANTEE_INCOME),

    USER_GUARANTEE_REPAYMENT("1112001", "担保保证金", "平台将担保保证金退还给担保人", "担保回款", BillFirstSubjectEnum.USER_GUARANTEE_REPAYMENT),

    USER_GUARANTEE_PAY_BACK_CORPUS("1114001", "垫付本金回款", "担保公司垫付投资人本金，借款人还款后，担保公司收取借款人本金", "垫付返还", BillFirstSubjectEnum.USER_GUARANTEE_PAY_BACK),
    USER_GUARANTEE_PAY_BACK_OVERDUE_FEE("1114003", "垫付回款罚息", "担保公司垫付投资人本金，借款人还款后，担保公司收取借款人本金罚息", "垫付返还", BillFirstSubjectEnum.USER_GUARANTEE_PAY_BACK),

    USER_RED("1118001", "领红包", "用户之间领红包", "用户领红包", BillFirstSubjectEnum.USER_RED),
    USER_RED_BACK("1118003", "红包退回", "红包退回", "红包", BillFirstSubjectEnum.USER_RED),
    USER_RED_TUNE("1118005", "尽调达人红包", "尽调达人活动平台奖励资金", "平台奖励", BillFirstSubjectEnum.USER_RED),//todo:数据库中不存在
    USER_RED_BORROW("1118007", "借款返现红包", "用户使用借款返现红包，借款成标后，平台返还红包金额给借款人", "平台奖励", BillFirstSubjectEnum.USER_RED),
    USER_RED_INVEST("1118009", "投资返现红包", "用户使用投资返现红包，借款成标后，平台返还红包金额给投资人", "平台奖励", BillFirstSubjectEnum.USER_RED),
    USER_RED_GUARANTEE("1118011", "担保返现红包", "用户使用担保返现红包，借款成标后，平台返还红包金额给担保人", "平台奖励", BillFirstSubjectEnum.USER_RED),
    USER_RED_COUPON_RATE_INTEREST("1118013", "加息券加息", "用户使用投资加息券，平台支付对应加息券利息收益", "平台奖励", BillFirstSubjectEnum.USER_RED),
    USER_RED_INVEST_COUPON("1118015", "投资代金券", "用户使用投资代金券，平台支付对应投资金额", "平台奖励", BillFirstSubjectEnum.USER_RED),//todo:数据库中不存在
    USER_RED_GUARANTEE_COUPON("1118017", "担保代金券", "用户使用担保代金券，平台支付对应担保保证金", "平台奖励", BillFirstSubjectEnum.USER_RED),//todo:数据库中不存在
    USER_RED_WITHDRAW_COUPON("1118019", "提现代金券", "用户使用提现代金券，平台支付对应提现手续费", "平台奖励", BillFirstSubjectEnum.USER_RED),
    USER_RED_OPEN_ACCOUNT("1118021", "开户余额返还", "用户开户后平台红包账户转到用户余额", "其他", BillFirstSubjectEnum.USER_RED),
    USER_RED_FINANCIAL_INTEREST("1118023", "理财金利息", "投资体验标完结，平台支付投资利息给用户", "平台奖励", BillFirstSubjectEnum.USER_RED),
    USER_RED_LINE_REPAYMENT("1118025", "线下资金处理", "因用户线下资金处理，平台账户支出给用户", "平台发放", BillFirstSubjectEnum.USER_RED),
    USER_RED_RECHARGE("1118027", "现金红包", "平台发放的现金充值红包", "平台发放", BillFirstSubjectEnum.USER_RED),
    USER_RED_CASH("1118029", "活动红包", "活动红包", "平台奖励", BillFirstSubjectEnum.USER_RED),
    USER_RED_FINANCIAL_INTEREST_INCOME("1118031", "理财金担保收益", "理财金担保收益", "平台奖励", BillFirstSubjectEnum.USER_RED),

    USER_PLATFORM_GIVEN_REGISTER("1120001", "推荐注册奖励", "推荐注册活动平台奖励", "平台奖励", BillFirstSubjectEnum.USER_PLATFORM_GIVEN),//todo:数据库中不存在
    USER_PLATFORM_GIVEN_INVEST("1120003", "推荐投资奖励", "推荐投资活动平台奖励", "平台奖励", BillFirstSubjectEnum.USER_PLATFORM_GIVEN),
    USER_PLATFORM_GIVEN_INVEST_CUMULATIVE("1120005", "推荐投资奖励", "推荐累计投资奖励【运营活动】", "平台奖励", BillFirstSubjectEnum.USER_PLATFORM_GIVEN),//todo:数据库中不存在
    USER_PLATFORM_GIVEN_INVEST_BONUS("1120007", "推荐投资奖励", "推荐投资分红金奖励【运营活动】", "平台奖励", BillFirstSubjectEnum.USER_PLATFORM_GIVEN),
    USER_PLATFORM_GIVEN_BORROW_BONUS("1120009", "推荐借款奖励", "推荐借款分红金奖励【运营活动】", "平台奖励", BillFirstSubjectEnum.USER_PLATFORM_GIVEN),
    USER_PLATFORM_GIVEN_BORROW("1120011", "推荐借款奖励", "推荐借款活动平台奖励", "平台奖励", BillFirstSubjectEnum.USER_PLATFORM_GIVEN),
    USER_PLATFORM_GIVEN_GUARANTEE("1120013", "推荐担保奖励", "推荐担保活动平台奖励", "平台奖励", BillFirstSubjectEnum.USER_PLATFORM_GIVEN),
    USER_PLATFORM_GIVEN_GUARANTEE_PERSON("1120015", "推荐担保人奖励", "推荐担保人认证【运营活动】", "平台奖励", BillFirstSubjectEnum.USER_PLATFORM_GIVEN),
    USER_PLATFORM_GIVEN_BORROWED("120017", "被推荐人借款奖励", "被推荐人借款，平台奖励被推荐人", "平台奖励", BillFirstSubjectEnum.USER_PLATFORM_GIVEN),
    USER_PLATFORM_GIVEN_BORROWED_FIRST("120019", "被推荐人借款奖励", "首次借款奖励【运营活动】", "平台奖励", BillFirstSubjectEnum.USER_PLATFORM_GIVEN),//todo:数据库中不存在
    USER_PLATFORM_GIVEN_INVESTED("1120021", "被推荐人投资奖励", "被推荐人投资，平台奖励被推荐人", "平台奖励", BillFirstSubjectEnum.USER_PLATFORM_GIVEN),//todo:数据库中不存在
    USER_PLATFORM_GIVEN_INVESTED_FIRST("1120023", "被推荐人投资奖励", "首次投资奖励【运营活动】", "平台奖励", BillFirstSubjectEnum.USER_PLATFORM_GIVEN),
    USER_PLATFORM_GIVEN_GUARANTEED("1120025", "被推荐人担保奖励", "被推荐人担保，平台奖励被推荐人", "平台奖励", BillFirstSubjectEnum.USER_PLATFORM_GIVEN),//todo:数据库中不存在
    USER_PLATFORM_GIVEN_GUARANTEED_FIRST("1120027", "被推荐人担保奖励", "首次担保奖励【运营活动】", "平台奖励", BillFirstSubjectEnum.USER_PLATFORM_GIVEN),//todo:数据库中不存在
    USER_PLATFORM_GIVEN_ACTIVITY_RAISE_INTEREST("1120028", "活动加息", "平台加息活动奖励", "平台奖励", BillFirstSubjectEnum.USER_PLATFORM_GIVEN),

    USER_SUBSIDY_BORROW("1122001", "借款人补贴", "平台给予借款人相关利息补贴、尽调费补贴、平台服务费补贴等【运营活动】", "平台奖励", BillFirstSubjectEnum.USER_SUBSIDY),
    USER_SUBSIDY_INVEST("1122003", "投资人补贴", "平台给与投资人相关投资服务费补贴等【运营活动】", "平台奖励", BillFirstSubjectEnum.USER_SUBSIDY),
    USER_SUBSIDY_TUNE("1122005", "尽调人补贴", "平台给与尽调人相关尽调费补贴等【运营活动】", "平台奖励", BillFirstSubjectEnum.USER_SUBSIDY),
    USER_SUBSIDY_GUARANTEE("1122007", "担保人补贴", "平台给予担保人相关尽调抢单补贴、担保服务费补贴、微担保补贴等【运营活动】", "平台奖励", BillFirstSubjectEnum.USER_SUBSIDY),

    USER_MECHANISM_REPLACEMENT_CORPUS("1124001", "代充本金", "极速借机构代借款人充值还款本金", "机构代充", BillFirstSubjectEnum.USER_MECHANISM_REPLACEMENT),
    USER_MECHANISM_REPLACEMENT_INTEREST("1124003", "代充利息", "极速借机构代借款人充值还款利息", "机构代充", BillFirstSubjectEnum.USER_MECHANISM_REPLACEMENT),
    USER_MECHANISM_REPLACEMENT_MANAGE_FEE("1124005", "代充平台管理费", "极速借机构代借款人充值还款平台管理费", "机构代充", BillFirstSubjectEnum.USER_MECHANISM_REPLACEMENT),
    USER_MECHANISM_REPLACEMENT_PRINCIPAL_PENALTY("1124007", "代充本金罚息", "极速借机构代借款人充值还款本金罚息", "机构代充", BillFirstSubjectEnum.USER_MECHANISM_REPLACEMENT),
    USER_MECHANISM_REPLACEMENT_INTEREST_PENALTY("1124009", "代充利息罚息", "极速借机构代借款人充值还款利息罚息", "机构代充", BillFirstSubjectEnum.USER_MECHANISM_REPLACEMENT),

    USER_BORROW_INCOME_AMOUNT("1126001", "借款金额", "借款成标后，借款人收取投资人投资金额", "借款", BillFirstSubjectEnum.USER_BORROW_INCOME),
    USER_BORROW_BACK_SERVICE_FEE("1126003","平台服务费退回","借款项目流标后，平台将平台服务费退回给借款人","借款",BillFirstSubjectEnum.USER_BORROW_INCOME),//todo:数据库中不存在
    USER_BORROW_BACK_SERVICE_FEE_YUNDAI("1126005","平台服务费退回【云贷】","借款项目流标后，平台将平台服务费退回给借款人","借款",BillFirstSubjectEnum.USER_BORROW_INCOME),
    USER_BORROW_BACK_GUARANTEE_SERVICE_FEE("1126007","担保服务费退回","借款项目流标后，平台将担保服务费退还借款人","借款",BillFirstSubjectEnum.USER_BORROW_INCOME),//todo:数据库中不存在
    USER_BORROW_BACK_GUARANTEE_SERVICE_FEE_YUNDAI("1126009","担保服务费退回【云贷】","借款项目流标后，平台将担保服务费退还借款人","借款",BillFirstSubjectEnum.USER_BORROW_INCOME),
    USER_BORROW_COMPENSATION("1126011","补尝金","补尝金","借款",BillFirstSubjectEnum.USER_BORROW_INCOME),

    USER_TRANSFER_IN("1128001", "划拨收入", "用户自己的3个子账户间转账", "资金划拨", BillFirstSubjectEnum.USER_TRANSFER_IN),

    USER_OTHER_IN("1130001", "投资人走账收入", "投资人走账收入", "其他收入", BillFirstSubjectEnum.USER_OTHER_IN),
    USER_OTHER_IN_ACTUALLY("1130003", "实际收入", "实际收入", "其他收入", BillFirstSubjectEnum.USER_OTHER_IN),
    USER_OTHER_IN_PLATFORM_RECHARGE("1130005", "虚拟账户平台充值", "虚拟账户平台充值资金", "其他", BillFirstSubjectEnum.USER_OTHER_IN),
    USER_OTHER_IN_CANCEL_CAPITAL("1130007", "虚拟账户撤销资金", "虚拟账户平台撤销资金", "其他", BillFirstSubjectEnum.USER_OTHER_IN),
    USER_OTHER_IN_GUARANTEE_RECHARGE("1130009", "代充值还款", "担保公司代借款人充值，用于借款人还款", "其他", BillFirstSubjectEnum.USER_OTHER_IN),//todo:数据库中不存在

    USER_REPAYMENT_BACK_CORPUS("1132001", "还款本金", "还款失败后，平台将还款本金退回借款人", "还款退回", BillFirstSubjectEnum.USER_REPAYMENT_BACK),
    USER_REPAYMENT_BACK_INTEREST("1132003", "还款利息", "还款失败后，平台将还款利息退回借款人", "还款退回", BillFirstSubjectEnum.USER_REPAYMENT_BACK),
    USER_REPAYMENT_BACK_OVERDUE_FINE("1132005", "罚息", "还款失败后，平台将罚息退回借款人", "还款退回", BillFirstSubjectEnum.USER_REPAYMENT_BACK),
    USER_REPAYMENT_BACK_PLATFORM_SERVICE_FEE("1132007", "平台管理费", "还款失败后，平台将平台管理费退回借款人", "还款退回", BillFirstSubjectEnum.USER_REPAYMENT_BACK),
    USER_REPAYMENT_BACK_GUARANTEE_SERVICE_FEE("1132009", "担保服务费", "还款失败后，平台将担保服务费退回借款人", "还款退回", BillFirstSubjectEnum.USER_REPAYMENT_BACK),

    USER_WITHDRAW("1200001", "提现金额", "用户提现", "提现", BillFirstSubjectEnum.USER_WITHDRAW),//todo:数据库中不存在
    USER_WITHDRAW_SERVICE_FEE("1200003", "提现手续费", "用户提现，平台收取用户提现手续费", "提现", BillFirstSubjectEnum.USER_WITHDRAW),

    USER_BORROW_SERVICE_FEE("1202001", "平台服务费", "借款成标后，平台收取借款人平台服务费", "借款", BillFirstSubjectEnum.USER_BORROW),
    USER_BORROW_GUARANTEE_SERVICE_FEE("1202003", "担保服务费", "借款成标后，担保公司收取借款人担保服务费", "借款", BillFirstSubjectEnum.USER_BORROW),
    USER_BORROW_PRE_ARBITRATION_SERVICE_FEE("1202005", "预仲裁服务费", "借款成标后，担保公司收取借款人预仲裁服务费", "借款", BillFirstSubjectEnum.USER_BORROW),//todo:数据库中不存在
    USER_BORROW_RECOMMENDED_SERVICE_FEE("1202007", "推荐服务费", "极速借机构借款成标后，极速借（机构）收取借款人推荐服务费", "借款", BillFirstSubjectEnum.USER_BORROW),
    USER_BORROW_TUNE("1202009", "尽调费", "信用借借款成标后，尽调人收取借款人尽调费", "借款", BillFirstSubjectEnum.USER_BORROW),
    USER_BORROW_GUARANTEE_FEE("1202011", "担保费", "信用借借款成标后，担保人收取借款人担保费", "借款", BillFirstSubjectEnum.USER_BORROW),
    USER_BORROW_SERVICE_FEE_OVERDUE_FINE("1202013", "平台服务费罚息", "平台服务费罚息", "借款", BillFirstSubjectEnum.USER_BORROW),//todo:数据库中不存在
    USER_BORROW_MANAGE_FEE("1202015", "平台管理费", "借款成标后，平台收取借款人平台管理费", "借款", BillFirstSubjectEnum.USER_BORROW),
    USER_BORROW_CONSULTING_FEE("1202017", "咨询服务费", "借款成标后，机构收取借款人咨询服务费", "借款", BillFirstSubjectEnum.USER_BORROW),//todo:数据库中不存在
    USER_BORROW_PRE_FEE("1202019", "前置服务费", "借款成标后，机构收取借款人咨询服务费", "借款", BillFirstSubjectEnum.USER_BORROW),

    USER_REPAYMENT_CORPUS("1204001", "还款本金", "投资人／担保人／担保公司收取借款人本金", "还款", BillFirstSubjectEnum.USER_REPAYMENT),
    USER_REPAYMENT_INTEREST("1204003", "还款利息", "投资人/担保公司收取借款人利息", "还款", BillFirstSubjectEnum.USER_REPAYMENT),
    USER_REPAYMENT_MANAGER_FEE("1204005", "平台管理费", "借款人每期还款，平台收取平台管理费", "还款", BillFirstSubjectEnum.USER_REPAYMENT),
    USER_REPAYMENT_GUARANTEE_FEE("1204006", "担保服务费", "借款人每期还款，担保公司收取借款人担保服务费", "还款", BillFirstSubjectEnum.USER_REPAYMENT),
    USER_REPAYMENT_COLLECT_FEE("1204007", "催收服务费", "借款人还款逾期，平台收取借款人催收服务费", "还款", BillFirstSubjectEnum.USER_REPAYMENT),
    USER_REPAYMENT_CONSULTING_FEE("1204008", "咨询服务费", "借款人还款，借款人支出咨询服务费", "还款", BillFirstSubjectEnum.USER_REPAYMENT),
    USER_REPAYMENT_CORPUS_PENALTY("1204009", "本金罚息", "借款人还款逾期，投资人/担保人/担保公司收取借款人本金罚息", "还款", BillFirstSubjectEnum.USER_REPAYMENT),
    USER_REPAYMENT_INTEREST_PENALTY("1204011", "利息罚息", "借款人还款逾期，担保公司收取借款人利息罚息", "还款", BillFirstSubjectEnum.USER_REPAYMENT),//todo:数据库中不存在
    USER_REPAYMENT_PENALTY("1204013", "罚息", "借款人还款逾期，投资人/担保公司收取借款人罚息", "还款", BillFirstSubjectEnum.USER_REPAYMENT),//todo:======存在两个1204013======
    USER_REPAYMENT_RISK("1204013", "支付垫付罚息", "借款人支付垫付罚息", "还款", BillFirstSubjectEnum.USER_REPAYMENT),//todo:======存在两个1204013======
    USER_REPAYMENT_MANAGE("1204015", "支付平台管理费", "借款人支付平台管理费", "还款", BillFirstSubjectEnum.USER_REPAYMENT),//todo:数据库中不存在
//    USER_REPAYMENT_ALL("204013","还款总额","借款人还款，本金+利息+罚息+管理费+服务费的总额记账，用于账单列表前台显示",USER_REPAYMENT,null,null,null,BillUserTypeEnum.user_type.getOrdinaryUser()),

    USER_INVEST("1206001", "投资金额", "借款成标后，借款人收取投资人投资金额", "投资", BillFirstSubjectEnum.USER_INVEST),
    USER_INVEST_SERVICE_FEE("1206003", "投资服务费", "借款成标后，平台收取投资人平台服务费", "投资", BillFirstSubjectEnum.USER_INVEST),

    USER_GUARANTEE_FEE("1208001", "担保保证金", "担保扣除保证金", "担保支出", BillFirstSubjectEnum.USER_GUARANTEE_OUTCOME),
    USER_GUARANTEE_OUTCOME("1208003", "担保服务费", "借款成标后，平台收取担保人平台服务费", "担保支出", BillFirstSubjectEnum.USER_GUARANTEE_OUTCOME),

    USER_GUARANTEE_PAY_ADVANCE("1210001", "垫付本金", "借款人未还款，担保人垫付本金", "担保垫付", BillFirstSubjectEnum.USER_GUARANTEE_PAY),
    USER_GUARANTEE_LATE_FEE("1210003", "滞纳金", "担保人垫付逾期，担保公司收取担保人滞纳金", "担保垫付", BillFirstSubjectEnum.USER_GUARANTEE_PAY),
    USER_GUARANTEE_RECEIVE_GUARANTOR_CORPUS("1210005", "垫付本金", "借款人未还款，担保人未垫付，担保公司垫付后，收取担保人垫付本金", "担保垫付", BillFirstSubjectEnum.USER_GUARANTEE_PAY),

    USER_TRANSFER_OUT("1212001", "划拨支出", "用户自己的3个子账户间转账", "资金划拨", BillFirstSubjectEnum.USER_TRANSFER_OUT),

    USER_RED_OUT_SEND("1214001", "发红包", "用户之间发红包", "用户发红包", BillFirstSubjectEnum.USER_RED_OUT),
    USER_RED_OUT_TUNE("1214003", "尽调达人红包退回", "尽调达人活动平台奖励退回", "尽调", BillFirstSubjectEnum.USER_RED_OUT),//todo:数据库中不存在
    USER_RED_OUT_INVEST_FLOW("1214005", "投资代金券-流标", "投资代金券-流标", "投资", BillFirstSubjectEnum.USER_RED_OUT),//todo:数据库中不存在
    USER_RED_OUT_GUARANTEE_FLOW("1214007", "担保代金券-流标", "担保代金券-流标", "担保", BillFirstSubjectEnum.USER_RED_OUT),//todo:数据库中不存在
    USER_RED_OUT_RETURN("1214009", "红包退回", "红包退回", "平台发放", BillFirstSubjectEnum.USER_RED_OUT),//todo:数据库中不存在
    USER_RED_OUT_WITHDRAW("1214011", "提现代金券", "提现代金券", "提现", BillFirstSubjectEnum.USER_RED_OUT),//todo:数据库中不存在

    USER_RECHARGE_OUT_AGENCY("1218001", "机构代充", "机构代充", "充值", BillFirstSubjectEnum.USER_RECHARGE_OUT),
    USER_RECHARGE_OUT_REPAYMENT("1218003", "锁定还款金额", "锁定还款金额", "充值", BillFirstSubjectEnum.USER_RECHARGE_OUT),

    USER_OVERDUE_MANAGE_THIRD("1220001", "三个月新增特别逾期管理费", "三个月新增特别逾期管理费", "逾期管理", BillFirstSubjectEnum.USER_OVERDUE_MANAGE),
    USER_OVERDUE_MANAGE_ONE("1220003", "一个月新增特别逾期管理费", "一个月新增特别逾期管理费", "逾期管理", BillFirstSubjectEnum.USER_OVERDUE_MANAGE),
    USER_OVERDUE_MANAGE_BASE("1220005", "基础逾期管理费", "基础逾期管理费", "逾期管理", BillFirstSubjectEnum.USER_OVERDUE_MANAGE),

    USER_OTHER_OUT_INVEST("1216001", "投资人走账支出", "投资人走账支出", "投资", BillFirstSubjectEnum.USER_OTHER_OUT),
    USER_OTHER_OUT_REAL("1216003", "实际支出", "实际支出", "投资", BillFirstSubjectEnum.USER_OTHER_OUT),

    USER_TRANSFER_CREDITOR_OUT_SERVICE_FEE("1222001", "转让服务费", "债权转让成功后,平台收取出让人转让服务费", "转让服务费", BillFirstSubjectEnum.USER_TRANSFER_CREDITOR_OUT),//todo:数据库中不存在

    /**
     * 合作机构（二级科目）
     */
    COOPERATE_AGENCY_RECHARGE("2100001", "充值金额", "充值", "充值金额", BillFirstSubjectEnum.COOPERATE_AGENCY_RECHARGE),

    COOPERATE_AGENCY_WITHDRAW_RETURN_AMOUNT("2102001", "提现金额退回", "机构提现申请失败，提现金额退回机构", "提现退回-提现金额", BillFirstSubjectEnum.COOPERATE_AGENCY_WITHDRAW_RETURN),//todo:数据库中不存在
    COOPERATE_AGENCY_WITHDRAW_RETURN_FEE("2102003", "提现手续费退回", "机构提现申请失败，平台将提现手续费退回机构", "提现退回-提现手续费", BillFirstSubjectEnum.COOPERATE_AGENCY_WITHDRAW_RETURN),//todo:数据库中不存在

    COOPERATE_AGENCY_SERVICE_FEE("2104001", "推荐服务费", "极速借机构借款成标后，极速借(机构)收取借款人推荐服务费", "借款-推荐服务费", BillFirstSubjectEnum.COOPERATE_AGENCY_SERVICE_FEE),//todo:数据库中不存在
    COOPERATE_BORROW_CONSULTING_FEE("2104003", "咨询服务费", "借款成标后，机构收取借款人咨询服务费", "借款", BillFirstSubjectEnum.COOPERATE_AGENCY_SERVICE_FEE),//todo:数据库中不存在
    COOPERATE_BORROW_PRE_FEE("2104005", "前置服务费", "借款成标后，机构收取借款人咨询服务费", "借款", BillFirstSubjectEnum.COOPERATE_AGENCY_SERVICE_FEE),

    COOPERATE_AGENCY_UNMARGIN_FEE("2106001", "释放保证金", "项目已流标或结清，系统释放机构保证金", "保证金", BillFirstSubjectEnum.COOPERATE_AGENCY_UNMARGIN_FEE),//todo:数据库中不存在

    COOPERATE_AGENCY_UNINSURANCE_FEE("2108001", "释放履约金", "系统释放机构的履约金", "履约金", BillFirstSubjectEnum.COOPERATE_AGENCY_UNINSURANCE_FEE),//todo:数据库中不存在

    COOPERATE_AGENCY_RECEIVE_CORPUS("2110001", "垫付本金回款", "机构账户垫付投资人本金，借款人还款后，收取借款人本金", "垫付回款", BillFirstSubjectEnum.COOPERATE_AGENCY_PAYMENT_RECEIVABLE),//todo:数据库中不存在
    COOPERATE_AGENCY_RECEIVE_INTEREST("2110003", "垫付利息回款", "机构账户垫付投资人利息，借款人还款后，收取借款人利息", "垫付回款", BillFirstSubjectEnum.COOPERATE_AGENCY_PAYMENT_RECEIVABLE),//todo:数据库中不存在
    COOPERATE_AGENCY_RECEIVE_OVERDUE_FINE("2110005", "垫付罚息回款", "机构账户垫付投资人罚息，借款人还款后，收取借款人罚息", "垫付回款", BillFirstSubjectEnum.COOPERATE_AGENCY_PAYMENT_RECEIVABLE),//todo:数据库中不存在
    COOPERATE_AGENCY_RECEIVE_PLATFORM_SERVICE_FEE("2110007", "垫付平台管理费回款", "机构账户垫付投资人平台管理费，借款人还款后，收取借款人平台管理费", "垫付回款", BillFirstSubjectEnum.COOPERATE_AGENCY_PAYMENT_RECEIVABLE),//todo:数据库中不存在
    COOPERATE_AGENCY_RECEIVE_GUARANTEE_SERVICE_FEE("2110009", "垫付担保服务费回款", "机构账户垫付投资人担保服务费，借款人还款后，收取借款人担保服务费", "垫付回款", BillFirstSubjectEnum.COOPERATE_AGENCY_PAYMENT_RECEIVABLE),//todo:数据库中不存在


    COOPERATE_AGENCY_WITHDRAW_AMOUNT("2200001", "提现金额", "机构提现", "提现-提现金额", BillFirstSubjectEnum.COOPERATE_AGENCY_WITHDRAW),
    COOPERATE_AGENCY_WITHDRAW_FEE("2200003", "提现手续费", "机构提现，平台收取提现手续费", "提现-提现手续费", BillFirstSubjectEnum.COOPERATE_AGENCY_WITHDRAW),

    COOPERATE_AGENCY_REPLACEMENT_PRINCIPAL("2202001", "代充本金", "极速借机构代借款人充值还款本金", "机构代充-本金", BillFirstSubjectEnum.COOPERATE_AGENCY_REPLACEMENT),//todo:数据库中不存在
    COOPERATE_AGENCY_REPLACEMENT_INTEREST("2202003", "代充利息", "极速借机构代借款人充值还款利息", "机构代充-利息", BillFirstSubjectEnum.COOPERATE_AGENCY_REPLACEMENT),//todo:数据库中不存在
    COOPERATE_AGENCY_REPLACEMENT_MANAGE_FEE("2202005", "代充平台管理费", "极速借机构代借款人充值还款平台管理费", "机构代充-平台管理费", BillFirstSubjectEnum.COOPERATE_AGENCY_REPLACEMENT),//todo:数据库中不存在
    COOPERATE_AGENCY_REPLACEMENT_PRINCIPAL_PENALTY("2202007", "代充本金罚息", "极速借机构代借款人充值还款本金罚息", "机构代充-本金罚息", BillFirstSubjectEnum.COOPERATE_AGENCY_REPLACEMENT),//todo:数据库中不存在
    COOPERATE_AGENCY_REPLACEMENT_INTEREST_PENALTY("2202009", "代充利息罚息", "极速借机构代借款人充值还款利息罚息", "机构代充-利息罚息", BillFirstSubjectEnum.COOPERATE_AGENCY_REPLACEMENT),//todo:数据库中不存在
    COOPERATE_AGENCY_REPLACEMENT_COMPENSATION_MONEY("2202011", "补偿金", "放款失败，支付借款人补偿金", "机构代充-代偿金", BillFirstSubjectEnum.COOPERATE_AGENCY_REPLACEMENT),//todo:数据库中不存在

    COOPERATE_AGENCY_MARGIN_FEE("2204001", "冻结保证金", "系统冻结机构推送标的的保证金", "保证金", BillFirstSubjectEnum.COOPERATE_AGENCY_MARGIN_FEE),//todo:数据库中不存在
    COOPERATE_AGENCY_INSURANCE_FEE("2206001", "冻结履约金", "系统冻结机构的履约金", "履约金", BillFirstSubjectEnum.COOPERATE_AGENCY_INSURANCE_FEE),//todo:数据库中不存在

    /**
     * 担保机构（二级科目）
     */
    GUARANTEE_AGENCY_RECHARGE("3100001", "充值金额", "担保公司充值", "充值金额", BillFirstSubjectEnum.GUARANTEE_AGENCY_RECHARGE),

    GUARANTEE_AGENCY_WITHDRAW_RETURN_AMOUNT("3102001", "提现金额退回", "担保公司提现申请失败，提现金额退回担保公司", "提现退回-提现金额", BillFirstSubjectEnum.GUARANTEE_AGENCY_WITHDRAW_RETURN),
    GUARANTEE_AGENCY_WITHDRAW_RETURN_FEE("3102003", "提现手续费退回", "担保公司提现申请失败，平台将提现手续费退回担保公司", "提现退回-提现手续费", BillFirstSubjectEnum.GUARANTEE_AGENCY_WITHDRAW_RETURN),

    GUARANTEE_AGENCY_ADVANCE_GUARANTEE_IN_REPAYMENT_PRINCIPAL("3104001", "垫付本金回款【借】", "担保公司垫付投资人本金，借款人还款后，担保公司收取借款人本金", "垫付返还", BillFirstSubjectEnum.GUARANTEE_AGENCY_ADVANCE_GUARANTEE_IN),
    GUARANTEE_AGENCY_ADVANCE_GUARANTEE_IN_REPAYMENT_INTEREST("3104003", "垫付利息回款【借】", "担保公司垫付投资人利息，借款人还款后，担保公司收取借款人利息", "垫付返还", BillFirstSubjectEnum.GUARANTEE_AGENCY_ADVANCE_GUARANTEE_IN),
    GUARANTEE_AGENCY_ADVANCE_GUARANTEE_IN_REPAYMENT_PENALTY("3104004", "垫付罚息回款【借】", "担保公司垫付投资人本金、利息、罚息，借款人还款后，担保公司收取借款人罚息", "垫付返还", BillFirstSubjectEnum.GUARANTEE_AGENCY_ADVANCE_GUARANTEE_IN),
    GUARANTEE_AGENCY_ADVANCE_GUARANTEE_IN_REPAYMENT_PRINCIPAL_PENALTY("3104005", "垫付本金罚息【借】", "担保公司垫付投资人本金，借款人还款后，担保公司收取借款人本金罚息", "垫付返还", BillFirstSubjectEnum.GUARANTEE_AGENCY_ADVANCE_GUARANTEE_IN),
    GUARANTEE_AGENCY_ADVANCE_GUARANTEE_IN_REPAYMENT_INTEREST_PENALTY("3104007", "垫付利息罚息【借】", "担保公司垫付投资人利息，借款人还款后，担保公司收取借款人利息罚息", "垫付返还", BillFirstSubjectEnum.GUARANTEE_AGENCY_ADVANCE_GUARANTEE_IN),
    GUARANTEE_AGENCY_ADVANCE_GUARANTEE_IN_GUARANTEE_FEE("3104009", "担保服务费【借】", "借款成标后，担保公司收取借款人担保服务费", "担保垫付", BillFirstSubjectEnum.GUARANTEE_AGENCY_ADVANCE_GUARANTEE_IN),
    GUARANTEE_AGENCY_ADVANCE_GUARANTEE_IN_PRE_ARBITRATION_FEE("3104011", "预仲裁服务费", "借款成标后，担保公司收取借款人预仲裁服务费", "担保垫付", BillFirstSubjectEnum.GUARANTEE_AGENCY_ADVANCE_GUARANTEE_IN),
    GUARANTEE_AGENCY_ADVANCE_GUARANTEE_IN_MANAGE_FEE("3104013", "垫付平台管理费回款", "担保公司垫付投资人平台管理费，借款人还款后，收取借款人平台管理费", "担保垫付", BillFirstSubjectEnum.GUARANTEE_AGENCY_ADVANCE_GUARANTEE_IN),//todo:数据库中不存在
    GUARANTEE_AGENCY_ADVANCE_GUARANTEE_IN_GUARANTEE_SERVICE_FEE("3104015", "垫付担保服务费回款", "担保公司垫付投资人担保服务费，借款人还款后，收取借款人担保服务费", "担保垫付", BillFirstSubjectEnum.GUARANTEE_AGENCY_ADVANCE_GUARANTEE_IN),//todo:数据库中不存在
    CONSULTING_FEE_IN("3108002", "垫付咨询服务费回款", "咨询公司/担保公司收取咨询服务费", "担保垫付", BillFirstSubjectEnum.GUARANTEE_AGENCY_REPAYMENT),

    GUARANTEE_AGENCY_GUARANTEE_REPAYMENT_PRINCIPAL("3106001", "垫付本金回款【担】", "担保人垫付逾期，担保公司收取担保人垫付本金", "担保回款", BillFirstSubjectEnum.GUARANTEE_AGENCY_GUARANTEE),
    GUARANTEE_AGENCY_GUARANTEE_LATE_FEE("3106003", "滞纳金", "担保人垫付逾期，担保公司收取担保人滞纳金", "担保回款", BillFirstSubjectEnum.GUARANTEE_AGENCY_GUARANTEE),
    GUARANTEE_AGENCY_GUARANTEE_SYSTEM_TEST("3106005", "系统测试用户担保", "担保公司上线后，进行系统测试，对用户进行担保。", "担保回款", BillFirstSubjectEnum.GUARANTEE_AGENCY_GUARANTEE),//todo:数据库中不存在

    GUARANTEE_AGENCY_IN_REPAYMENT("3108001", "担保服务费【借】", "借款人还款，担保公司收取担保服务费", "还款", BillFirstSubjectEnum.GUARANTEE_AGENCY_REPAYMENT),



    //回滚
    GUARANTEE_AGENCY_ADVANCE_BACK_CORPUS("3110001", "垫付本金退回", "垫付失败，垫付本金退回担保公司/合作机构", "垫付退回", BillFirstSubjectEnum.GUARANTEE_AGENCY_ADVANCE_GUARANTEE_IN_BACK),
    GUARANTEE_AGENCY_ADVANCE_BACK_INTEREST("3110003", "垫付利息退回", "垫付失败，垫付利息退回担保公司/合作机构", "垫付退回", BillFirstSubjectEnum.GUARANTEE_AGENCY_ADVANCE_GUARANTEE_IN_BACK),
    GUARANTEE_AGENCY_ADVANCE_BACK_OVERDUE_FINE("3110004", "垫付罚息退回", "垫付失败，垫付罚息退回担保公司/合作机构", "垫付退回", BillFirstSubjectEnum.GUARANTEE_AGENCY_ADVANCE_GUARANTEE_IN_BACK),//todo:数据库中不存在
    GUARANTEE_AGENCY_ADVANCE_BACK_PLATFORM_SERVICE_FEE("3110005", "垫付平台管理费退回", "垫付失败，垫付平台管理费退回担保公司/合作机构", "垫付退回", BillFirstSubjectEnum.GUARANTEE_AGENCY_ADVANCE_GUARANTEE_IN_BACK),//todo:数据库中不存在
    GUARANTEE_AGENCY_ADVANCE_BACK_GUARANTEE_SERVICE_FEE("3110006", "垫付担保服务费退回", "垫付失败，垫付担保服务费退回担保公司/合作机构", "垫付退回", BillFirstSubjectEnum.GUARANTEE_AGENCY_ADVANCE_GUARANTEE_IN_BACK),//todo:数据库中不存在


    GUARANTEE_AGENCY_WITHDRAW_AMOUNT("3200001", "提现金额", "担保公司提现", "提现-提现金额", BillFirstSubjectEnum.GUARANTEE_AGENCY_WITHDRAW),
    GUARANTEE_AGENCY_WITHDRAW_FEE("3200003", "提现手续费", "担保公司提现，平台收取提现手续费", "提现-提现手续费", BillFirstSubjectEnum.GUARANTEE_AGENCY_WITHDRAW),

    GUARANTEE_AGENCY_ADVANCE_GUARANTEE_OUT_PRINCIPAL_SPEED_BORROW("3202001", "垫付本金", "借款人未还本金，担保/机构账户垫付投资人第%s期本金", "担保垫付", BillFirstSubjectEnum.GUARANTEE_AGENCY_ADVANCE_GUARANTEE_OUT),
    GUARANTEE_AGENCY_ADVANCE_GUARANTEE_OUT_PRINCIPAL_SPEED_AGENCY("3202003", "垫付本金【极速借机构】", "借款人未还本金，担保账户垫付投资人本金", "担保垫付", BillFirstSubjectEnum.GUARANTEE_AGENCY_ADVANCE_GUARANTEE_OUT),//todo:数据库中不存在
    GUARANTEE_AGENCY_ADVANCE_GUARANTEE_OUT_PRINCIPAL_CREDIT_BORROW("3202005", "垫付本金【信用借】", "借款人未还本金，担保人未垫付本金，担保账户垫付投资人本金", "担保垫付", BillFirstSubjectEnum.GUARANTEE_AGENCY_ADVANCE_GUARANTEE_OUT),
    GUARANTEE_AGENCY_ADVANCE_GUARANTEE_OUT_INTEREST("3202007", "垫付利息", "借款人未还利息，担保/机构账户垫付投资人第%s期利息", "担保垫付", BillFirstSubjectEnum.GUARANTEE_AGENCY_ADVANCE_GUARANTEE_OUT),
    GUARANTEE_AGENCY_ADVANCE_GUARANTEE_OUT_PENALTY("3202008", "垫付罚息", "借款人未还罚息，担保/机构账户垫付罚息", "担保垫付", BillFirstSubjectEnum.GUARANTEE_AGENCY_ADVANCE_GUARANTEE_OUT),//todo:数据库中不存在
    GUARANTEE_AGENCY_ADVANCE_GUARANTEE_OUT_COMPENSATION_MONEY("3202009", "补尝金", "放款失败，项目需执行提前结清，由担保公司支付利息等相关费用", "担保垫付", BillFirstSubjectEnum.GUARANTEE_AGENCY_ADVANCE_GUARANTEE_OUT),
    GUARANTEE_AGENCY_ADVANCE_GUARANTEE_OUT_BYBACK("3202011", "垫付回购", "借款人未还本息，担保公司回购", "担保垫付", BillFirstSubjectEnum.GUARANTEE_AGENCY_ADVANCE_GUARANTEE_OUT),
    GUARANTEE_AGENCY_ADVANCE_GUARANTEE_OUT_CORPUS_XIAOFEI_BORROW("3202013", "偿付本金【消费借】", "借款人未还本金，担保账户垫付投资人本金", "担保垫付", BillFirstSubjectEnum.GUARANTEE_AGENCY_ADVANCE_GUARANTEE_OUT),//todo:数据库中不存在
    GUARANTEE_AGENCY_ADVANCE_GUARANTEE_OUT_CORPUS_SPEED_BORROW("3202015", "偿付本金【极速借】", "借款人未还本金，担保账户垫付投资人本金", "担保垫付", BillFirstSubjectEnum.GUARANTEE_AGENCY_ADVANCE_GUARANTEE_OUT),//todo:数据库中不存在
    GUARANTEE_AGENCY_GUARANTEE_PENALTY("3202017", "垫付罚息【借】", "担保公司垫付投资人，借款人还款后，担保公司收取借款人罚息", "担保垫付", BillFirstSubjectEnum.GUARANTEE_AGENCY_ADVANCE_GUARANTEE_OUT),//todo:数据库中不存在
    GUARANTEE_AGENCY_ADVANCE_GUARANTEE_OUT_MANAGE_FEE("3202019", "垫付平台管理费", "借款人未还平台管理费，担保/机构账户垫付平台管理费", "担保垫付", BillFirstSubjectEnum.GUARANTEE_AGENCY_ADVANCE_GUARANTEE_OUT),
    GUARANTEE_AGENCY_ADVANCE_GUARANTEE_OUT_GUARANTEE_FEE("3202021", "垫付担保服务费", "借款人未还担保服务费，担保/机构账户垫付担保服务费", "担保垫付", BillFirstSubjectEnum.GUARANTEE_AGENCY_ADVANCE_GUARANTEE_OUT),
    GUARANTEE_AGENCY_ADVANCE_GUARANTEE_OUT_CONSULTING_FEE("3202022", "垫付咨询服务费", "借款人未还咨询服务费，担保账户垫付咨询服务费", "担保垫付", BillFirstSubjectEnum.GUARANTEE_AGENCY_ADVANCE_GUARANTEE_OUT),

    GUARANTEE_AGENCY_ADVANCE_OTHER("3204001", "担保服务费退回【云贷】", "借款项目流标后，平台将担保服务费退回借款人", "借款流标-担保服务费", BillFirstSubjectEnum.GUARANTEE_AGENCY_ADVANCE_OTHER),


    /**
     * 平台（二级科目）
     */
    PLATFORM_SERVICE_FEE_IN_SPEED_BORROWING("4100001", "平台服务费【极速借】", "极速借借款成标后，平台收取借款人平台服务费", null, BillFirstSubjectEnum.PLATFORM_SERVICE_FEE_IN ),
    PLATFORM_SERVICE_FEE_IN_SPEED_BORROWING_AGENCY("4100003", "平台服务费【极速借机构】", "极速借机构借款成标后，平台收取借款人平台服务费", null, BillFirstSubjectEnum.PLATFORM_SERVICE_FEE_IN ),//todo:数据库中不存在
    PLATFORM_SERVICE_FEE_IN_CREDIT_BORROWING("4100005", "平台服务费【信用借】", "信用借借款成标后，平台收取借款人平台服务费", null, BillFirstSubjectEnum.PLATFORM_SERVICE_FEE_IN),
    PLATFORM_SERVICE_FEE_IN_MANAGE_SPEED_BORROWING("4100007", "平台管理费", "借款人还款，平台/担保公司收取平台管理费", null, BillFirstSubjectEnum.PLATFORM_SERVICE_FEE_IN),
    PLATFORM_SERVICE_FEE_IN_MANAGE_SPEED_BORROWING_AGENCY("4100009", "平台管理费【极速借机构】", "信用借借款人每期还款，平台收取平台管理费", null, BillFirstSubjectEnum.PLATFORM_SERVICE_FEE_IN),
    PLATFORM_SERVICE_FEE_IN_INVEST("4100011", "平台服务费【投】", "借款成标后，平台收取投资人平台服务费", null, BillFirstSubjectEnum.PLATFORM_SERVICE_FEE_IN),
    PLATFORM_SERVICE_FEE_IN_GUARANTEE("4100015", "平台服务费【担】", "借款成标后，平台收取担保人平台服务费", null, BillFirstSubjectEnum.PLATFORM_SERVICE_FEE_IN),
    PLATFORM_SERVICE_FEE_IN_COLLECTION("4100017", "催收服务费", "借款人还款逾期，平台收取借款人催收服务费", null, BillFirstSubjectEnum.PLATFORM_SERVICE_FEE_IN),
    PLATFORM_SERVICE_FEE_IN_WITHDRAW("4100019", "提现手续费", "用户提现，平台收取用户提现手续费", null, BillFirstSubjectEnum.PLATFORM_SERVICE_FEE_IN),
    PLATFORM_SERVICE_FEE_IN_WITHDRAW_AGENCY("4100021", "提现手续费", "机构用户提现，平台收取机构用户提现手续费", null, BillFirstSubjectEnum.PLATFORM_SERVICE_FEE_IN),
    PLATFORM_SERVICE_FEE_IN_SERVICE_FEE_XIAOFEI_BORROW("4100023", "平台服务费【消费借】", "极速借机构借款成标后，平台收取借款人平台服务费", null, BillFirstSubjectEnum.PLATFORM_SERVICE_FEE_IN),
    PLATFORM_SERVICE_FEE_IN_MANAGE_FEE_XIAOFEI_BORROW("4100025", "平台管理费【消费借】", "极速借机构借款人每期还款，平台收取平台管理费", null, BillFirstSubjectEnum.PLATFORM_SERVICE_FEE_IN),
    PLATFORM_SERVICE_FEE_IN_MANAGE_CREDIT_BORROWING("4100027", "平台管理费【信用借构】", "极速借机构借款人每期还款，平台收取平台管理费", null, BillFirstSubjectEnum.PLATFORM_SERVICE_FEE_IN),
    PLATFORM_SERVICE_FEE_IN_TRANSFER_CREDITOR("4100029", "债权转让服务费", "债权转让成功后,平台收取出让人转让服务费", null, BillFirstSubjectEnum.PLATFORM_SERVICE_FEE_IN),//todo:数据库中不存在
    PLATFORM_BORROW_MANAGE_FEE("4100031", "平台管理费", "借款成标后，平台收取借款人平台管理费", "借款", BillFirstSubjectEnum.PLATFORM_SERVICE_FEE_IN),

    PLATFORM_WITHDRAW_BACK("4102001", "平台提现金额退回", "平台账户提现失败，退回平台提现金额", null, BillFirstSubjectEnum.PLATFORM_WITHDRAW_BACK),//todo:数据库中不存在
    PLATFORM_WITHDRAW_BACK_FEE("4102003", "平台提现手续费退回", "平台账户提现失败，退回平台提现手续费", null, BillFirstSubjectEnum.PLATFORM_WITHDRAW_BACK),//todo:数据库中不存在

    PLATFORM_RECHARGE("4104001", "平台充值", "平台充值", null, BillFirstSubjectEnum.PLATFORM_RECHARGE),

    PLATFORM_RED_IN_INVEST("4106001", "投资代金券退回", "用户使用投资代金券，平台支付对应投资金额，因项目流标，系统退回投资金额", null, BillFirstSubjectEnum.PLATFORM_RED_IN),
    PLATFORM_RED_IN_WITHDRAW("4106003", "提现代金券退回", "用户使用提现代金券，平台支付对应提现手续费，因提现失败，系统退回提现手续费", null, BillFirstSubjectEnum.PLATFORM_RED_IN),
    PLATFORM_RED_IN_GUARANTEE("4106005", "担保代金券退回", "用户使用担保代金券，平台支付对应担保金额，因项目流标，系统退回担保金额", null, BillFirstSubjectEnum.PLATFORM_RED_IN),
    PLATFORM_RED_IN_TUNE("4106007", "尽调达人红包退回", "尽调达人活动平台奖励资金退回", null, BillFirstSubjectEnum.PLATFORM_RED_IN),

    PLATFORM_OTHER_IN_REAL_INCOME("4108001", "用户账户异常处理【实收收入】", "因线下还款、网贷欺诈等用户账户异常事件平台账户的实收收入", null, BillFirstSubjectEnum.PLATFORM_OTHER_IN),
    PLATFORM_OTHER_IN_PROCESS_INCOME("4108003", "用户账户异常处理【流程收入】", "因线下还款、网贷欺诈等用户账户异常事件平台账户的走账收入", null, BillFirstSubjectEnum.PLATFORM_OTHER_IN),
    PLATFORM_OTHER_IN_FREEZE_BAIL("4108005", "冻结保证金", "扣除用户保证金", null, BillFirstSubjectEnum.PLATFORM_OTHER_IN),

    PLATFORM_TRANSFER("4110001", "子账户转账", "子账户间转账", null, BillFirstSubjectEnum.PLATFORM_TRANSFER),

    PLATFORM_SERVICE_FEE_OUT_INVEST("4200001", "投资服务费退回", "借款项目流标后，平台将投资服务费退还投资人", null, BillFirstSubjectEnum.PLATFORM_SERVICE_FEE_OUT),
    PLATFORM_SERVICE_FEE_OUT_WITHDRAW("4200003", "提现手续费退回", "用户提现申请失败，提现手续费退回用户", null, BillFirstSubjectEnum.PLATFORM_SERVICE_FEE_OUT),
    PLATFORM_SERVICE_FEE_OUT_RECHARGE("4200005", "用户充值服务费", "用户账户充值，平台支付充值服务费", null, BillFirstSubjectEnum.PLATFORM_SERVICE_FEE_OUT),//todo:数据库中不存在
    PLATFORM_SERVICE_FEE_OUT_RECHARGE_SERVICE_FEE("4200007", "平台充值服务费", "平台账户充值，平台支付充值服务费", null, BillFirstSubjectEnum.PLATFORM_SERVICE_FEE_OUT),//todo:数据库中不存在
    PLATFORM_SERVICE_FEE_OUT_TREATY_FEE("4200009", "代扣服务费", "用户账户代扣，平台支付代扣服务费", null, BillFirstSubjectEnum.PLATFORM_SERVICE_FEE_OUT),//todo:数据库中不存在

    PLATFORM_WITHDRAW_SERVICE_FEE("4202001", "平台提现手续费", "平台账户提现，平台支付提现手续费", null, BillFirstSubjectEnum.PLATFORM_WITHDRAW),//todo:数据库中不存在
    PLATFORM_WITHDRAW_AMOUNT("4202003", "平台提现金额", "平台账户提现", null, BillFirstSubjectEnum.PLATFORM_WITHDRAW),

    PLATFORM_OTHER_OUT_REAL("4204001", "用户账户异常处理【实收支出】", "因线下还款、网贷欺诈等用户账户异常事件平台账户的实收支出", null, BillFirstSubjectEnum.PLATFORM_OTHER_OUT),
    PLATFORM_OTHER_OUT_TAKE_ACCOUNT("4204003", "用户账户异常处理【走账支出】", "因线下还款、网贷欺诈等用户账户异常事件平台账户的走账支出", null, BillFirstSubjectEnum.PLATFORM_OTHER_OUT),
    PLATFORM_OTHER_OUT_PLATFORM_FEE_BACK("4204005", "平台服务费退回【云贷】", "借款项目流标后，平台将平台服务费退回借款人", null, BillFirstSubjectEnum.PLATFORM_OTHER_OUT),
    PLATFORM_OTHER_OUT_PLATFORM_GUARANTEE_OUT("4204007", "平台担保支出", "平台担保支出", null, BillFirstSubjectEnum.PLATFORM_OTHER_OUT),
    PLATFORM_OTHER_OUT_PLATFORM_GURANTEE_INVEST("4204009", "担保理财金", "用户使用担保理财金", null, BillFirstSubjectEnum.PLATFORM_OTHER_OUT),

    PLATFORM_PREMIUM_CONTRIBUTION_INVEST("4206001", "投资服务费捐献", "投资人确认投资时，你我金融收取投资人投资服务费的100%转入质保金", null, BillFirstSubjectEnum.PLATFORM_PREMIUM_CONTRIBUTION),
    PLATFORM_PREMIUM_CONTRIBUTION_INVEST_PROPORTION("4206003", "投资服务费捐献", "投资服务费捐献,平台账户划拨质保金账户，金额:1.92", null, BillFirstSubjectEnum.PLATFORM_PREMIUM_CONTRIBUTION),//todo:数据库中不存在
    PLATFORM_PREMIUM_CONTRIBUTION_FEE_SPEED_BORROWING("4206005", "平台服务费捐献【极速借】", "极速借借款成标后，平台收取借款人的平台服务费的10%转入质保金", null, BillFirstSubjectEnum.PLATFORM_PREMIUM_CONTRIBUTION),
    PLATFORM_PREMIUM_CONTRIBUTION_MANAGE_FEE_SPEED_BORROWING("4206007", "平台管理费捐献【极速借】", "极速借借款人每期还款需支付平台管理费的50%转入质保金", null, BillFirstSubjectEnum.PLATFORM_PREMIUM_CONTRIBUTION),
    PLATFORM_PREMIUM_CONTRIBUTION_MANAGE_FEE_SPEED_BORROWING_PROPORTION("4206009", "平台管理费捐献【极速借】", "极速借借款人每期还款需支付平台管理费的100%转入质保金", null, BillFirstSubjectEnum.PLATFORM_PREMIUM_CONTRIBUTION),//todo:数据库中不存在
    PLATFORM_PREMIUM_CONTRIBUTION_FEE_CREDIT_BORROWING("4206011", "平台服务费捐献【信用借】", "信用借借款成标后，平台收取借款人的平台服务费的10%转入质保金", null, BillFirstSubjectEnum.PLATFORM_PREMIUM_CONTRIBUTION),
    PLATFORM_PREMIUM_CONTRIBUTION_MANAGE_FEE_CREDIT_BORROWING("4206013", "平台管理费捐献【信用借】", "信用借借款人每期还款需支付平台管理费的10%转入质保金", null, BillFirstSubjectEnum.PLATFORM_PREMIUM_CONTRIBUTION),//todo:数据库中不存在
    PLATFORM_PREMIUM_CONTRIBUTION_FEE_SPEED_BORROWING_AGENCY("4206015", "平台服务费捐献【极速借机构】", "极速借(机构)借款成标后，平台收取借款人的平台服务费的10%转入质保金", null, BillFirstSubjectEnum.PLATFORM_PREMIUM_CONTRIBUTION),//todo:数据库中不存在
    PLATFORM_PREMIUM_CONTRIBUTION_MANAGE_FEE_SPEED_BORROWING_AGENCY("4206017", "平台管理费捐献【极速借机构】", "极速借(机构)借款人每期还款需支付平台管理费的10%转入质保金", null, BillFirstSubjectEnum.PLATFORM_PREMIUM_CONTRIBUTION),
    PLATFORM_PREMIUM_CONTRIBUTION_GUARANTEE("4206019", "担保服务费捐献", "借款成标后，你我金融收取担保人担保服务费的100%转入质保金", null, BillFirstSubjectEnum.PLATFORM_PREMIUM_CONTRIBUTION),
    PLATFORM_PREMIUM_CONTRIBUTION_PLATFORM("4206021", "平台捐献", "平台捐献", null, BillFirstSubjectEnum.PLATFORM_PREMIUM_CONTRIBUTION),//todo:数据库中不存在
    PLATFORM_PREMIUM_CONTRIBUTION_PLATFORM_DONATION_SERVICE("4206023", "平台服务费捐献【消费借】", "极速借(机构)借款成标后，平台收取借款人的平台服务费的10%转入质保金", null, BillFirstSubjectEnum.PLATFORM_PREMIUM_CONTRIBUTION),
    PLATFORM_PREMIUM_CONTRIBUTION_PLATFORM_DONATION_MANAGE("4206025", "平台管理费捐献【消费借】", "极速借(机构)借款人每期还款需支付平台管理费的10%转入质保金", null, BillFirstSubjectEnum.PLATFORM_PREMIUM_CONTRIBUTION),

    PLATFORM_EXPERIENCE_BID_GUARANTEE_INCOME("4208001", "平台支出担保收益", "担保体验标完结，平台支付担保收益给用户", null, BillFirstSubjectEnum.PLATFORM_EXPERIENCE_BID),
    PLATFORM_EXPERIENCE_BID_INVEST_INTEREST_PLATFORM("4208003", "平台支出投资利息", "投资体验标完结，平台支付投资利息给用户", null, BillFirstSubjectEnum.PLATFORM_EXPERIENCE_BID),//todo:数据库中不存在
    PLATFORM_EXPERIENCE_BID_INVEST_INTEREST_BORROWER("4208005", "平台支出投资利息", "借款人支付投资人利息", null, BillFirstSubjectEnum.PLATFORM_EXPERIENCE_BID),

    PLATFORM_RED_OUT_INVEST("4210001", "投资返现红包支出", "用户使用投资返现红包，借款成标后，平台返还红包金额给投资人", null, BillFirstSubjectEnum.PLATFORM_RED_OUT),
    PLATFORM_RED_OUT_INVEST_PROFIT("4210003", "投资返现红包支出", "投资返现红包返现收益", null, BillFirstSubjectEnum.PLATFORM_RED_OUT),//todo:数据库中不存在
    PLATFORM_RED_OUT_WITHDRAW("4210005", "提现代金券支出", "用户使用提现代金券，平台支付对应提现手续费", null, BillFirstSubjectEnum.PLATFORM_RED_OUT),
    PLATFORM_RED_OUT_TUNE("4210007", "尽调达人红包支出", "尽调达人活动平台奖励资金", null, BillFirstSubjectEnum.PLATFORM_RED_OUT),
    PLATFORM_RED_OUT_INVEST_CASH_COUPON("4210009", "投资代金券支出", "用户使用投资代金券，平台支付对应投资金额", null, BillFirstSubjectEnum.PLATFORM_RED_OUT),
    PLATFORM_RED_OUT_INVEST_COUPON("4210011", "投资加息券利息支出", "用户使用投资加息券，平台支付对应加息券利息收益", null, BillFirstSubjectEnum.PLATFORM_RED_OUT),
    PLATFORM_RED_OUT_CASH("4210013", "现金红包", "平台发放现金红包给用户", null, BillFirstSubjectEnum.PLATFORM_RED_OUT),
    PLATFORM_RED_OUT_GUARANTEE_RETURN("4210015", "担保返现红包支出", "用户使用担保返现红包，借款成标后，平台返还红包金额给担保人", null, BillFirstSubjectEnum.PLATFORM_RED_OUT),
    PLATFORM_RED_OUT_GUARANTEE_CASH_COUPON("4210017", "担保代金券支出", "用户使用担保代金券，平台支付对应担保保证金", null, BillFirstSubjectEnum.PLATFORM_RED_OUT),
    PLATFORM_RED_OUT_BORROW_RETURN("4210019", "借款返现红包支出", "用户使用借款返现红包，借款成标后，平台返还红包金额给借款人", null, BillFirstSubjectEnum.PLATFORM_RED_OUT),
    PLATFORM_RED_OUT_OPEN_ACCOUNT_RETURN("4210021", "开户余额返还", "用户开户后平台红包账户转到用户余额", null, BillFirstSubjectEnum.PLATFORM_RED_OUT),
    PLATFORM_RED_LINE_REPAYMENT("4210023", "用户线下资金处理", "因用户线下资金处理，平台营销款账户支出给用户", null, BillFirstSubjectEnum.PLATFORM_RED_OUT),

    PLATFORM_MARKETING_RECOMMEND_LOAN("4212001", "推荐借款奖励", "推荐借款活动平台奖励", null, BillFirstSubjectEnum.PLATFORM_MARKETING_INCENTIVES),
    PLATFORM_MARKETING_RECOMMEND_LOAN_BONUS("4212003", "推荐借款奖励", "用户邀请其他人完成借款可获得分红金【运营活动】", null, BillFirstSubjectEnum.PLATFORM_MARKETING_INCENTIVES),
    PLATFORM_MARKETING_RECOMMEND_TUNE("4212005", "尽调奖励", "尽调报告审核通过，但尽调人放弃担保或项目流标，平台给予尽调人奖励", null, BillFirstSubjectEnum.PLATFORM_MARKETING_INCENTIVES),
    //推荐担保人奖励这个地方暂时先这样定义，有疑问需商讨
    PLATFORM_MARKETING_RECOMMEND_GUARANTOR_COMPLETE("4212007", "推荐担保人奖励", "用户邀请其他人完成担保人资格奖励【运营活动】", null, BillFirstSubjectEnum.PLATFORM_MARKETING_INCENTIVES),//todo:数据库中不存在
    PLATFORM_MARKETING_RECOMMEND_GUARANTOR_COMPLETE_BONUS("4212009", "推荐担保人奖励", "用户邀请其他人完成担保人资格（钱小保、钱大保、个人微担保）奖励【运营活动】", null, BillFirstSubjectEnum.PLATFORM_MARKETING_INCENTIVES),//todo:数据库中不存在
    PLATFORM_MARKETING_RECOMMEND_GUARANTOR("4212011", "推荐担保人奖励", "邀请好友活动：用户推荐其他人完成钱小保资格申请相关奖励【运营活动】", null, BillFirstSubjectEnum.PLATFORM_MARKETING_INCENTIVES),//todo:数据库中不存在
    PLATFORM_MARKETING_RECOMMEND_MICRO_GUARANTOR_COMPLETE_QIAN("4212013", "推荐担保人奖励", "邀请好友活动：用户推荐其他人完成钱小保资格申请相关奖励【运营活动】", null, BillFirstSubjectEnum.PLATFORM_MARKETING_INCENTIVES),
    PLATFORM_MARKETING_RECOMMEND_MICRO_GUARANTOR_COMPLETE_WEI("4212015", "推荐担保人奖励", "推荐微担保活动：用户推荐其他人完成微担保资格申请相关奖励【运营活动】", null, BillFirstSubjectEnum.PLATFORM_MARKETING_INCENTIVES),
    PLATFORM_MARKETING_RECOMMEND_MICRO_GUARANTEE("4212017", "推荐担保人奖励", "推荐微担保活动：被他人推荐且成功通过微担保资格申请的用户相关奖励【运营活动】", null, BillFirstSubjectEnum.PLATFORM_MARKETING_INCENTIVES),
    PLATFORM_MARKETING_RECOMMEND_BONUS("4212019", "推荐担保人奖励", "推荐担保人活动平台奖励", null, BillFirstSubjectEnum.PLATFORM_MARKETING_INCENTIVES),//todo:数据库中不存在
    PLATFORM_MARKETING_RECOMMEND_INVESTOR("4212021", "推荐投资奖励", "用户邀请投资人完成投资相关奖励【运营活动】", null, BillFirstSubjectEnum.PLATFORM_MARKETING_INCENTIVES),//todo:数据库中不存在
    PLATFORM_MARKETING_RECOMMEND_INVESTED_BONUS("4212023", "推荐投资奖励", "用户邀请其他人完成投资每日可获得分红金【运营活动】", null, BillFirstSubjectEnum.PLATFORM_MARKETING_INCENTIVES),
    PLATFORM_MARKETING_RECOMMEND_INVESTED_OTHERPERSON("4212025", "推荐投资奖励", "邀请好友活动：用户邀请其他人完成投资相关奖励【运营活动】", null, BillFirstSubjectEnum.PLATFORM_MARKETING_INCENTIVES),
    PLATFORM_MARKETING_RECOMMEND_INVESTED("4212027", "推荐投资奖励", "推荐投资活动平台奖励", null, BillFirstSubjectEnum.PLATFORM_MARKETING_INCENTIVES),//todo:数据库中不存在
    PLATFORM_MARKETING_RECOMMEND_REGISTER_AGENCY("4212029", "推荐注册奖励", "代理人活动：代理人推荐其他人成功注册，平台给予相关奖励【运营活动】", null, BillFirstSubjectEnum.PLATFORM_MARKETING_INCENTIVES),//todo:数据库中不存在
    PLATFORM_MARKETING_RECOMMEND_GUARANTEE_COMPLETE_FIRST("4212031", "推荐担保奖励", "用户邀请其他人完成首次担保相关奖励【运营活动】", null, BillFirstSubjectEnum.PLATFORM_MARKETING_INCENTIVES),
    PLATFORM_MARKETING_RECOMMEND_GUARANTEE("4212033", "推荐担保奖励", "推荐担保活动平台奖励", null, BillFirstSubjectEnum.PLATFORM_MARKETING_INCENTIVES),//todo:数据库中不存在
    PLATFORM_MARKETING_RECOMMEND_GUARANTEED("4212035", "被推荐人担保奖励", "被推荐人担保，平台奖励被推荐人", null, BillFirstSubjectEnum.PLATFORM_MARKETING_INCENTIVES),//todo:数据库中不存在
    PLATFORM_MARKETING_RECOMMEND_GUARANTEED_COMPLETE_FIRST("4212037", "被推荐人担保奖励", "完成首次担保【运营活动】", null, BillFirstSubjectEnum.PLATFORM_MARKETING_INCENTIVES),//todo:数据库中不存在
    PLATFORM_MARKETING_RECOMMEND_BORROW("4212039", "被推荐人借款奖励", "被推荐人投资，平台奖励被推荐人", null, BillFirstSubjectEnum.PLATFORM_MARKETING_INCENTIVES),//todo:数据库中不存在
    PLATFORM_MARKETING_RECOMMEND_BORROW_COMPLETE_FIRST("4212041", "被推荐人借款奖励", "完成首次借款【运营活动】", null, BillFirstSubjectEnum.PLATFORM_MARKETING_INCENTIVES),
    PLATFORM_MARKETING_RECOMMEND_INVEST("4212043", "被推荐人投资奖励", "被推荐人借款，平台奖励被推荐人", null, BillFirstSubjectEnum.PLATFORM_MARKETING_INCENTIVES),//todo:数据库中不存在
    PLATFORM_MARKETING_RECOMMEND_INVEST_COMPLETE("4212045", "被推荐人投资奖励", "完成首次投资【运营活动】", null, BillFirstSubjectEnum.PLATFORM_MARKETING_INCENTIVES),
    PLATFORM_MARKETING_RECOMMEND_REGISTER("4212047", "推荐注册奖励", "推荐注册活动平台奖励", null, BillFirstSubjectEnum.PLATFORM_MARKETING_INCENTIVES),//todo:数据库中不存在
    PLATFORM_GIVEN_ACTIVITY_RAISE_INTEREST("4212048", "活动加息奖励", "平台加息活动奖励", null, BillFirstSubjectEnum.PLATFORM_MARKETING_INCENTIVES),

    PLATFORM_SUBSIDIES_BORROW_INTEREST_RETURN("4214001", "借款人补贴", "借款利息返现：借款成标后，平台返还借款人的利息【借款利率折扣卡】", null, BillFirstSubjectEnum.PLATFORM_SUBSIDIES),
    PLATFORM_SUBSIDIES_INTEREST("4214003", "借款人补贴", "借款利息补贴：借款成标后，平台给予借款人的利息补贴【运营活动】", null, BillFirstSubjectEnum.PLATFORM_SUBSIDIES),
    PLATFORM_SUBSIDIES_TUNE("4214005", "借款人补贴", "尽调费补贴：借款成标后，平台给予借款人尽调费补贴【运营活动】", null, BillFirstSubjectEnum.PLATFORM_SUBSIDIES),
    PLATFORM_SUBSIDIES_GUARANTEE("4214007", "担保人补贴", "尽调抢单补贴：尽调人按要求抢单并完成尽调，平台给予尽调人抢单补贴【运营活动】", null, BillFirstSubjectEnum.PLATFORM_SUBSIDIES),
    PLATFORM_SUBSIDIES_INVEST("4214009", "投资人补贴", "投资补贴：借款成标后，平台给予投资人的补贴【运营活动】", null, BillFirstSubjectEnum.PLATFORM_SUBSIDIES),//todo:数据库中不存在
    PLATFORM_SUBSIDIES_BORROW_INTEREST_SERVICE("4214011", "借款人补贴", "平台服务费补贴：借款成标后，平台给予借款人平台服务费补贴【运营活动】", null, BillFirstSubjectEnum.PLATFORM_SUBSIDIES),

    PLATFORM_TRANSFER_OUT("4216001", "子账户转账", "子账户间转账", null, BillFirstSubjectEnum.PLATFORM_TRANSFER_OUT),

    ZHIBAOJIN_BORROW_CORPUS("5100001", "偿付本金回款【借】", "质保金偿付投资人本金；借款人还款后，质保金偿付的本金退回质保金", null, BillFirstSubjectEnum.ZHIBAOJIN_INVEST),//todo:数据库中不存在
    ZHIBAOJIN_BORROW_INTEREST_FINE("5100003", "偿付利息罚息【借】", "质保金偿付投资人利息；借款人还款后，质保金偿付的利息罚息转入质保金", null, BillFirstSubjectEnum.ZHIBAOJIN_INVEST),//todo:数据库中不存在
    ZHIBAOJIN_BORROW_INTEREST("5100005", "偿付利息回款【借】", "质保金偿付投资人利息；借款人还款后，质保金偿付的利息退回质保金", null, BillFirstSubjectEnum.ZHIBAOJIN_INVEST),//todo:数据库中不存在
    ZHIBAOJIN_BORROW_CORPUS_FINE("5100007", "偿付本金罚息【借】", "质保金偿付投资人本金；借款人还款后，质保金偿付的本金罚息转入质保金", null, BillFirstSubjectEnum.ZHIBAOJIN_INVEST),//todo:数据库中不存在

    ZHIBAOJIN_GUARANTEE_FINE_DELAYING("5102001", "担保滞纳金", "担保人未垫付，质保金偿付投资人本息，担保人延期垫付所产生的滞纳金全部转入质保金(你我金融最初版本历史数据迁移2017-02-07)", null, BillFirstSubjectEnum.ZHIBAOJIN_GUARANTEE),//todo:数据库中不存在
    ZHIBAOJIN_GUARANTEE_CORPUS_RECEIVE("5102003", "偿付本金回款【担】", "担保人未垫付，质保金偿付投资人本金；担保人垫付后，质保金偿付的本金退回质保金(你我金融最初版本历史数据迁移2017-02-07)", null, BillFirstSubjectEnum.ZHIBAOJIN_GUARANTEE),//todo:数据库中不存在

    ZHIBAOJIN_PLATFORM_DONATION("5104001", "平台捐献", "质保金停用后账户余额捐献给担保公司-2990769.81元", null, BillFirstSubjectEnum.ZHIBAOJIN_PLATFORM),
    ZHIBAOJIN_PLATFORM_DONATION_SERVICE_FEE_CREDIT_BORROW("5104003", "平台服务费捐献【信用借】", "信用借借款成标后，你我金融收取借款人的平台服务费的10%转入质保金", null, BillFirstSubjectEnum.ZHIBAOJIN_PLATFORM),
    ZHIBAOJIN_PLATFORM_DONATION_SERVICE_SPEED_BORROW("5104005", "平台服务费捐献【极速借】", "极速借借款成标后，你我金融收取借款人的平台服务费的10%转入质保金", null, BillFirstSubjectEnum.ZHIBAOJIN_PLATFORM),
    ZHIBAOJIN_PLATFORM_DONATION_MANAGE_CREDIT_BORROW("5104007", "平台管理费捐献【信用借】", "信用借借款人每期还款需支付平台管理费的10%转入质保金(你我金融最初版本历史数据迁移2017-02-07)", null, BillFirstSubjectEnum.ZHIBAOJIN_PLATFORM),
    ZHIBAOJIN_PLATFORM_DONATION_MANAGE_SPEED_BORROW("5104009", "平台管理费捐献【极速借】", "极速借借款人每期还款需支付平台管理费全部转入质保金【资金管理优化2017-02-07】", null, BillFirstSubjectEnum.ZHIBAOJIN_PLATFORM),
    ZHIBAOJIN_PLATFORM_DONATION_MANAGE_XIAOFEIJIE("5104011", "平台管理费捐献【消费借】", "极速借(机构)借款人每期还款需支付平台管理费的10%转入质保金", null, BillFirstSubjectEnum.ZHIBAOJIN_PLATFORM),
    ZHIBAOJIN_PLATFORM_DONATION_SERVICE_FEE_XIAOFEIJIE("5104013", "平台服务费捐献【消费借】", "极速借(机构)借款成标后，你我金融收取借款人的平台服务费的10%转入质保金", null, BillFirstSubjectEnum.ZHIBAOJIN_PLATFORM),
    ZHIBAOJIN_PLATFORM_BASE_OVERDUE_MANAGE_FEE("5104015", "基础逾期管理费", "悄悄借逾期一个月内，收取借款人管理费全部转入质保金", null, BillFirstSubjectEnum.ZHIBAOJIN_PLATFORM),
    ZHIBAOJIN_PLATFORM_SPACIAL_OVERDUE_MANAGE_FEE("5104017", "特别逾期管理费【一个月】", "悄悄借逾期超一个月，收取借款人管理费全部转入质保金", null, BillFirstSubjectEnum.ZHIBAOJIN_PLATFORM),
    ZHIBAOJIN_PLATFORM_SPACIAL_OVERDUE_MANAGE_FEE_THREE("5104019", "特别逾期管理费【三个月】", "悄悄借逾期超三个月，收取借款人管理费全部转入质保金", null, BillFirstSubjectEnum.ZHIBAOJIN_PLATFORM),
    ZHIBAOJIN_PLATFORM_DONATION_SERVICE_FEE_SPEED_AGENCY("5104021", "平台服务费捐献【极速借机构】", "极速借(机构)借款成标后，你我金融收取借款人的平台服务费的10%转入质保金", null, BillFirstSubjectEnum.ZHIBAOJIN_PLATFORM),//todo:数据库中不存在
    ZHIBAOJIN_PLATFORM_DONATION_MANAGE_SPEED_AGENCY("5104023", "平台管理费捐献【极速借机构】", "极速借(机构)借款人每期还款需支付平台管理费的10%转入质保金", null, BillFirstSubjectEnum.ZHIBAOJIN_PLATFORM),//todo:数据库中不存在
    ZHIBAOJIN_PLATFORM_DONATION_INVEST_FEE("5104025", "投资服务费捐献", "借款成标后，你我金融收取投资人投资服务费的100%转入质保金【资金管理优化2017-02-07】", null, BillFirstSubjectEnum.ZHIBAOJIN_PLATFORM),
    ZHIBAOJIN_PLATFORM_DONATION_SERVICE_FEE("5104027", "担保服务费捐献", "借款成标后，你我金融收取担保人担保服务费的100%转入质保金【资金管理优化2017-02-07】", null, BillFirstSubjectEnum.ZHIBAOJIN_PLATFORM),

    ZHIBAOJIN_INVEST_RECEIVE_INTEREST("5200001", "投资回款利息", "借款人未还利息，质保金偿付投资人利息(数据修复)", null, BillFirstSubjectEnum.ZHIBAOJIN_INVEST),//todo:数据库中不存在
    ZHIBAOJIN_INVEST_PRINCIPAL_CORPUS_SPEED_BORROW("5200003", "偿付本金【极速借】", "借款人未还本金，质保金偿付投资人本金", null, BillFirstSubjectEnum.ZHIBAOJIN_INVEST),//todo:数据库中不存在
    ZHIBAOJIN_INVEST_PRINCIPAL_CORPUS_CREDIT_BORROW("5200005", "偿付本金【信用借】", "借款人未还本金，担保人未垫付本金，质保金偿付投资人本金(你我金融最初版本历史数据迁移2017-02-07)", null, BillFirstSubjectEnum.ZHIBAOJIN_INVEST),//todo:数据库中不存在
    ZHIBAOJIN_INVEST_PRINCIPAL_INTEREST("5200007", "偿付利息", "借款人未还利息，质保金偿付投资人利息(你我金融最初版本历史数据迁移2017-02-07)", null, BillFirstSubjectEnum.ZHIBAOJIN_INVEST),//todo:数据库中不存在

    GUARANTEE_MARGIN_IN("6100001", "冻结保证金", "担保人确认担保借款，系统冻结相应保证金(你我金融最初版本历史数据迁移2017-02-07)", null, BillFirstSubjectEnum.GUARANTEE_MARGIN_IN),//todo:数据库中不存在
    GUARANTEE_MARGIN_IN_AGENCY("6100003", "冻结保证金", "系统冻结机构推送标的的保证金：12.00元", null, BillFirstSubjectEnum.GUARANTEE_MARGIN_IN),

    GUARANTEE_MARGIN_OUT("6200001", "释放保证金", "借款人已还款，系统释放担保人相应保证金(你我金融最初版本历史数据迁移2017-02-07)", null, BillFirstSubjectEnum.GUARANTEE_MARGIN_OUT),
    GUARANTEE_MARGIN_OUT_AGENCY("6200003", "释放保证金", "项目已流标，系统释放机构保证金:12.00元", null, BillFirstSubjectEnum.GUARANTEE_MARGIN_OUT),

    ;

    private String code;
    private String codeName;
    private String desc;
    private String title;
    private BillFirstSubjectEnum firstSubject;//所属一级科目

    @AllArgsConstructor
    @Getter
    public enum InoutTypeEnum {
        IN_TYPE((byte) 1, "收入"),
        OUT_TYPE((byte) -1, "支出");

        private Byte type; //收支类型
        private String desc;  //类型说明

        public static InoutTypeEnum getEnumByCode(Byte enumCode) {
            if (Objects.nonNull(enumCode)) {
                for (InoutTypeEnum retEnum : InoutTypeEnum.values()) {
                    if (enumCode == retEnum.type) {
                        return retEnum;
                    }
                }
            }
            return null;
        }
    }

    /**
     * 处理中状态的账单list
     *
     * @return
     */
    public static List<String> listDealStatusEnum() {
        List<String> list = new ArrayList<>();
        list.add(BillFirstSubjectEnum.USER_WITHDRAW.getCode());
        list.add(BillFirstSubjectEnum.USER_INVEST.getCode());
        return list;
    }

    /**
     * 当前期数需要填充账单的list
     *
     * @return
     */
    public static List<String> listCurrentPeriodEnum() {
        List<String> list = new ArrayList<>();
        list.add(BillFirstSubjectEnum.USER_INVEST_REPAYMENT.getCode());
        list.add(BillFirstSubjectEnum.USER_REPAYMENT.getCode());
        return list;
    }

    /**
     * 投资奖励的账单list
     *
     * @return
     */
    public static List<String> listInvestBonusEnum() {
        List<String> list = new ArrayList<>();
        list.add(BillSecondSubjectEnum.USER_PLATFORM_GIVEN_INVEST.getCode());
        list.add(BillSecondSubjectEnum.USER_PLATFORM_GIVEN_INVEST_CUMULATIVE.getCode());
        list.add(BillSecondSubjectEnum.USER_PLATFORM_GIVEN_INVEST_BONUS.getCode());
        list.add(BillSecondSubjectEnum.USER_SUBSIDY_INVEST.getCode());
        list.add(BillSecondSubjectEnum.USER_RED_INVEST.getCode());
        list.add(BillSecondSubjectEnum.USER_RED_COUPON_RATE_INTEREST.getCode());
        list.add(BillSecondSubjectEnum.USER_RED_INVEST_COUPON.getCode());
        list.add(BillSecondSubjectEnum.USER_RED_FINANCIAL_INTEREST.getCode());
        return list;
    }

    /**
     * 需要填充卡Code的list
     *
     * @return
     */
    public static List<String> listBankImagEnum() {
        List<String> list = new ArrayList<>();
        //"100","1200","1100","102","1202","1102","200","2200","2100"
        list.add(BillSecondSubjectEnum.USER_RECHARGE.getCode());
        list.add(BillSecondSubjectEnum.USER_WITHDRAW_BACK.getCode());
        list.add(BillSecondSubjectEnum.USER_WITHDRAW.getCode());
        list.add(BillSecondSubjectEnum.COOPERATE_AGENCY_RECHARGE.getCode());
        list.add(BillSecondSubjectEnum.COOPERATE_AGENCY_WITHDRAW_RETURN_AMOUNT.getCode());
        list.add(BillSecondSubjectEnum.COOPERATE_AGENCY_WITHDRAW_AMOUNT.getCode());
        list.add(BillSecondSubjectEnum.GUARANTEE_AGENCY_RECHARGE.getCode());
        list.add(BillSecondSubjectEnum.GUARANTEE_AGENCY_WITHDRAW_RETURN_AMOUNT.getCode());
        list.add(BillSecondSubjectEnum.GUARANTEE_AGENCY_WITHDRAW_AMOUNT.getCode());
        return list;
    }

    /**
     * 担保机构交易类型（不涉及个人的）
     * @return
     */
    public static List<String> listGuaranteeTranctionType(){
        List<String> list = new ArrayList<>();
        list.add(BillSecondSubjectEnum.GUARANTEE_AGENCY_RECHARGE.getCode());
        list.add(BillSecondSubjectEnum.GUARANTEE_AGENCY_WITHDRAW_RETURN_AMOUNT.getCode());
        list.add(BillSecondSubjectEnum.GUARANTEE_AGENCY_WITHDRAW_RETURN_FEE.getCode());
        list.add(BillSecondSubjectEnum.GUARANTEE_AGENCY_WITHDRAW_AMOUNT.getCode());
        list.add(BillSecondSubjectEnum.GUARANTEE_AGENCY_WITHDRAW_FEE.getCode());
        return list;
    }


    public static BillSecondSubjectEnum getEnumByCode(String enumCode) {
        if (Objects.nonNull(enumCode)) {
            for (BillSecondSubjectEnum retEnum : BillSecondSubjectEnum.values()) {
                if (enumCode.equals(retEnum.code)) {
                    return retEnum;
                }
            }
        }
        return null;
    }

}
